<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>
<body>
  <script>
    let uname = 'zs'
    // 对象的键 是可以不加 '' 的 
    // 对象中的键 [属性]  会解析成变量的  es6的语法
    let obj = {a: 10, [uname]: 18}
    console.log(obj);
  </script>
</body>
</html>